package com.example.demo.domain.vo;

import com.example.demo.domain.entity.Course;
import com.example.demo.domain.entity.Student;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;
import java.util.Objects;

@AllArgsConstructor
@NoArgsConstructor
@Data
public class StudentCourseGradesVO {
    private Student student;
    private List<CourseGradesVO> courseGradesVOList;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        StudentCourseGradesVO that = (StudentCourseGradesVO) o;
        return Objects.equals(student, that.student) && Objects.equals(courseGradesVOList, that.courseGradesVOList);
    }

    @Override
    public int hashCode() {
        return Objects.hash(student, courseGradesVOList);
    }
}
